* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background-color: #f8f9fa;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    flex: 1;
}

header {
    text-align: center;
    margin-bottom: 30px;
    background: #ffffff;
    color: #2c3e50;
    padding: 30px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border: 1px solid #e9ecef;
}

header h1 {
    font-size: 2rem;
    margin-bottom: 20px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #495057;
}

.status-bar {
    display: flex;
    justify-content: center;
    gap: 40px;
    font-size: 1rem;
    font-weight: 500;
    color: #6c757d;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border: 1px solid #e9ecef;
    overflow: hidden;
}

main {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 30px;
    margin-bottom: 40px;
}

.signin-section, .signin-list-section {
    padding: 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    background: linear-gradient(135deg,#232526,#414345);
    color: white;
    border-radius: 12px 12px 0 0;
}

.section-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.signin-section > div:not(.section-header),
.signin-list-section > div:not(.section-header) {
    padding: 30px;
}

.signin-form {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

input[type="text"] {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s ease;
    background-color: #f8f9fa;
}

input[type="text"]:focus {
    outline: none;
    border-color: #667eea;
    background-color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

/* 按钮样式 */
.btn {
    padding: 12px 24px;
    border: 1px solid transparent;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-decoration: none;
    min-width: 100px;
}

.btn-primary {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

.btn-primary:hover {
    background: #0056b3;
    border-color: #0056b3;
}

.btn-secondary {
    background: #6c757d;
    color: white;
    border-color: #6c757d;
}

.btn-secondary:hover {
    background: #545b62;
    border-color: #545b62;
}

.btn-danger {
    background: #dc3545;
    color: white;
    border-color: #dc3545;
}

.btn-danger:hover {
    background: #c82333;
    border-color: #c82333;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #e9ecef !important;
    color: #6c757d !important;
    border-color: #e9ecef !important;
}

.btn:disabled:hover {
    background: #e9ecef !important;
    border-color: #e9ecef !important;
}

/* 已签到状态的特殊样式 */
.btn-primary.signed-in {
    background: #28a745 !important;
    border-color: #28a745 !important;
    cursor: default !important;
    opacity: 1 !important;
}

.btn-primary.signed-in:hover {
    background: #28a745 !important;
    border-color: #28a745 !important;
}

.message {
    padding: 12px 16px;
    border-radius: 4px;
    margin-top: 12px;
    font-size: 14px;
    display: none;
    border: 1px solid transparent;
}

.message.success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
    display: block;
}

.message.error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
    display: block;
}

.message.signed-in {
    background: linear-gradient(135deg, #e8f5e8 0%, #f0f8f0 100%);
    color: #2d5a2d;
    border: 2px solid #4caf50;
    border-radius: 8px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.2);
}

.message.signed-in i {
    font-size: 24px;
    color: #4caf50;
    flex-shrink: 0;
}

.signed-in-info {
    flex: 1;
}

.signed-in-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 8px;
    color: #2d5a2d;
}

.signed-in-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.signed-in-details span {
    font-size: 13px;
    color: #4a6741;
    background: rgba(76, 175, 80, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    display: inline-block;
}

/* 列表样式 */
.list-actions {
    display: flex;
    gap: 10px;
}

.signin-list {
    padding-right: 10px;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}



/* 签到项目样式 */
.signin-item {
    transition: opacity 0.2s ease;
}

/* 当前用户签到记录样式 */
.signin-item.current-user {
    border-left: 3px solid #28a745;
    background: #f8f9fa;
}

.current-user-badge {
    color: #28a745;
    font-weight: 500;
    font-size: 0.9em;
    margin-left: 6px;
}



.list-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.signin-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    background-color: #ffffff;
    border-radius: 12px;
    border-left: 4px solid #667eea;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin-bottom: 16px;
    height: 80px;
    min-height: 80px;
    border: 1px solid #f1f3f4;
}

.signin-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.signin-item:hover::before {
    opacity: 1;
}

.signin-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.signin-item .delete-btn {
    padding: 10px 16px;
    background-color: transparent;
    color: #dc3545;
    border: 1px solid #dc3545;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    opacity: 0.8;
    position: relative;
    overflow: hidden;
    margin-left: 16px;
    min-width: 80px;
}

.signin-item:hover .delete-btn {
    opacity: 1;
}

.signin-item .delete-btn:hover {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.signin-item .delete-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(220, 53, 69, 0.3);
}

.signin-item .delete-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s ease;
}

.signin-item .delete-btn:hover::before {
    left: 100%;
}

.signin-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.signin-info .signin-name {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 2px;
}

.signin-info .signin-time,
.signin-info .signin-id {
    font-size: 14px;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 2px 0;
}

.signin-info h3 {
    font-size: 16px;
    margin-bottom: 4px;
    color: #2c3e50;
    font-weight: 600;
}

.signin-time {
    font-size: 14px;
    color: #7f8c8d;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* 空状态样式 */
.empty-message {
    text-align: center;
    color: #6c757d;
    font-size: 16px;
    padding: 60px 30px;
    background-color: #ffffff;
    border-radius: 16px;
    border: 2px dashed #dee2e6;
    margin: 24px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.empty-message:hover {
    border-color: #adb5bd;
    background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
}

.empty-message i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
    display: block;
}

.empty-message p {
    margin: 0;
    font-size: 16px;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background-color: white;
    border-radius: 6px;
    width: 90%;
    max-width: 450px;
    border: 1px solid #dee2e6;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    border-radius: 6px 6px 0 0;
}

.modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
    color: #495057;
}

.close-btn {
    background: none;
    border: none;
    color: #6c757d;
    font-size: 20px;
    cursor: pointer;
    padding: 4px;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: #495057;
}

.modal-body {
    padding: 20px;
    font-size: 14px;
    color: #495057;
}

.modal-body p {
    margin: 0;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 16px 20px;
    border-top: 1px solid #dee2e6;
}

/* 页脚样式 */
footer {
    text-align: center;
    margin-top: 30px;
    padding: 20px;
    background: #f8f9fa;
    color: #6c757d;
    border-top: 1px solid #e9ecef;
    font-size: 13px;
}

footer p {
    margin: 0;
    line-height: 1.5;
}

.footer-subtitle {
    font-size: 12px;
    opacity: 0.8;
    margin-top: 4px !important;
}



/* 响应式设计 */
@media (max-width: 1024px) {
    .container {
        padding: 15px;
    }
    
    header {
        padding: 30px 15px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .status-bar {
        gap: 40px;
    }
    
    .section-header {
        padding: 20px 25px;
    }
    
    .signin-section > div:not(.section-header),
    .signin-list-section > div:not(.section-header) {
        padding: 25px;
    }
}

/* 响应式优化 - PC端宽屏优化 */
@media (min-width: 1200px) {
    body {
        padding: 0 2%;
    }
    
    .uk-card-body {
        padding: 30px;
    }
    
    .uk-card-header {
        padding: 20px 30px;
    }
    
    /* 主要内容区域在大屏幕上使用更多空间 */
    .uk-grid-medium {
        margin-left: -20px;
    }
    
    .uk-grid-medium > * {
        padding-left: 20px;
    }
}

@media (min-width: 1600px) {
    body {
        padding: 0 3%;
    }
    
    .uk-card-body {
        padding: 40px;
    }
    
    .uk-card-header {
        padding: 25px 40px;
    }
}

/* 超宽屏优化 */
@media (min-width: 1920px) {
    body {
        padding: 0 5%;
    }
}

/* 网格视图样式 */
.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 24px;
    padding: 24px;
}

.grid-view .signin-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px 16px;
    margin-bottom: 0;
    height: 160px;
    justify-content: space-between;
    border: 1px solid #e9ecef;
    border-radius: 16px;
    background: white;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.grid-view .signin-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.grid-view .signin-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 24px rgba(0,0,0,0.15);
}

.grid-view .signin-item.current-user::before {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.grid-view .signin-item.current-user {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.05) 0%, rgba(32, 201, 151, 0.05) 100%);
    border-color: #28a745;
}

.grid-view .signin-item .signin-info {
    align-items: center;
    gap: 12px;
    width: 100%;
    flex: 1;
    justify-content: center;
}

.grid-view .signin-item .signin-name {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    justify-content: center;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.grid-view .signin-item .signin-name i {
    color: #667eea;
    font-size: 16px;
}

.grid-view .signin-item .signin-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    margin-top: 8px;
}

.grid-view .signin-item .signin-time {
    font-size: 11px;
    justify-content: center;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 4px;
}

.grid-view .signin-item .signin-time i {
    font-size: 10px;
    color: #95a5a6;
}

.grid-view .signin-item .signin-id {
    font-size: 11px;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 4px;
}

.grid-view .signin-item .signin-id i {
    font-size: 10px;
    color: #95a5a6;
}

.grid-view .signin-item .delete-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 4px 6px;
    font-size: 10px;
    opacity: 0;
    transition: all 0.3s ease;
}

.grid-view .signin-item:hover .delete-btn {
    opacity: 1;
}

.grid-view .signin-item .current-user-badge {
    font-size: 10px;
    padding: 1px 6px;
    margin-left: 4px;
}

/* 响应式网格布局 */
@media (max-width: 1600px) {
    .grid-view {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (max-width: 1200px) {
    .grid-view {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    .grid-view {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }
    
    .grid-view .signin-item {
        min-height: 100px;
        padding: 12px 8px;
    }
}

@media (max-width: 480px) {
    .grid-view {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .grid-view .signin-item {
        min-height: 90px;
        padding: 10px 6px;
    }
    
    .grid-view .signin-item .signin-name {
        font-size: 12px;
    }
    
    .grid-view .signin-item .signin-time,
    .grid-view .signin-item .signin-id {
        font-size: 10px;
    }
}

/* 列表视图样式（默认） */
.list-view {
    display: flex;
    flex-direction: column;
    padding: 24px;
}

/* 视图切换按钮样式 */
.uk-button-group .uk-button.uk-active {
    background-color: #667eea;
    color: white;
    border-color: #667eea;
}

/* 确保卡片容器自适应高度 */
.uk-card {
    height: auto !important;
}

.uk-card-body {
    height: auto !important;
}

/* 自适应高度的签到列表容器 */
.signin-list-container {
    min-height: 200px;
    height: auto;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
}

/* 空状态时的高度 */
.signin-list-container:has(.empty-message) {
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 新的卡片式签到记录样式 */
.signin-item {
    background: white;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.signin-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 0 2px 2px 0;
}

.signin-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.signin-item.current-user::before {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.signin-item.current-user {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.05) 0%, rgba(32, 201, 151, 0.05) 100%);
    border-color: #28a745;
}

/* 签到信息布局优化 */
.signin-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.signin-name {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 8px;
}

.signin-name i {
    color: #667eea;
    width: 16px;
}

.signin-details {
    display: flex;
    gap: 24px;
    align-items: center;
}

.signin-time,
.signin-id {
    font-size: 14px;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 6px;
}

.signin-time i,
.signin-id i {
    color: #95a5a6;
    width: 14px;
}

/* 删除按钮优化 */
.signin-item .delete-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 6px 10px;
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.2);
    border-radius: 6px;
    font-size: 12px;
    opacity: 0;
    transition: all 0.3s ease;
    cursor: pointer;
}

.signin-item:hover .delete-btn {
    opacity: 1;
}

.signin-item .delete-btn:hover {
    background: #dc3545;
    color: white;
    transform: scale(1.05);
}

/* 当前用户标识 */
.current-user-badge {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    margin-left: 8px;
}

/* Logo优化样式 */
.uk-navbar-container {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.uk-navbar-item.uk-logo img {
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

/* 卡片阴影优化 */
.uk-card-default {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
}

.uk-card-default:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* 头部状态栏统计卡片统一高度设置 */
.status-cards-grid .uk-card.uk-card-default {
    height: 160px;
    display: flex;
    flex-direction: column;
}

.status-cards-grid .uk-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.status-cards-grid .uk-card-body .uk-margin-small-top {
    margin-top: 12px !important;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

@media (max-width: 768px) {
    main {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    header h1 {
        font-size: 1.8rem;
    }
    
    .status-bar {
        flex-direction: column;
        gap: 15px;
    }
    
    /* 移动端状态栏统计卡片高度调整 */
    .status-cards-grid .uk-card.uk-card-default {
        height: 140px;
    }
    
    .status-cards-grid .uk-card-body {
        padding: 16px;
    }
    
    #currentDate {
        font-size: 12px !important;
    }
    
    #currentTime {
        font-size: 16px !important;
    }
    
    .status-bar .status-item {
        justify-content: center;
    }
    
    .signin-form {
        flex-direction: column;
    }
    
    .section-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .list-actions {
        justify-content: center;
    }
    
    .signin-item {
        flex-direction: column;
        gap: 15px;
        text-align: center;
        align-items: center;
    }
    
    .signin-item .delete-btn {
        width: 100%;
        max-width: 150px;
        justify-content: center;
    }
    
    .modal-content {
        width: 95%;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 1.5rem;
    }
    
    .section-header h2 {
        font-size: 1.3rem;
    }
    
    .signin-section > div:not(.section-header),
    .signin-list-section > div:not(.section-header) {
        padding: 20px;
    }
    
    .modal-body {
        padding: 25px 20px;
    }
    
    .modal-footer {
        flex-direction: column;
        padding: 0 20px 20px;
    }
    
    .modal-footer .btn {
        width: 100%;
    }
}

/* 时间卡片特殊样式 */
.status-cards-grid .time-card .uk-margin-small-top {
    margin-top: 12px !important;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

#currentDate {
    color: #495057;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    font-size: 14px !important;
}

#currentTime {
    color: #2c3e50;
    font-family: 'Courier New', monospace;
    letter-spacing: 1px;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    font-size: 16px !important;
}



/* 响应式调整 - 在较大屏幕上使用水平布局 */
@media (min-width: 768px) {
    .datetime-display {
        flex-direction: row;
        gap: 12px;
        justify-content: center;
        align-items: baseline;
    }
    
    #currentDate {
        font-size: 15px !important;
    }
    
    #currentTime {
        font-size: 18px !important;
    }
}